3.124 \(\int \frac {\sec ^5(c+d x)}{(a+i a \tan (c+d x))^2} \, dx\)

Optimal. Leaf size=74 \[ \frac {3 \tanh ^{-1}(\sin (c+d x))}{2 a^2 d}-\frac {2 i \sec ^3(c+d x)}{d \left (a^2+i a^2 \tan (c+d x)\right )}+\frac {3 \tan (c+d x) \sec (c+d x)}{2 a^2 d} \]

[Out]

3/2*arctanh(sin(d*x+c))/a^2/d+3/2*sec(d*x+c)*tan(d*x+c)/a^2/d-2*I*sec(d*x+c)^3/d/(a^2+I*a^2*tan(d*x+c))

________________________________________________________________________________________

Rubi [A]  time = 0.06, antiderivative size = 74, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 24, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {3500, 3768, 3770} \[ \frac {3 \tanh ^{-1}(\sin (c+d x))}{2 a^2 d}-\frac {2 i \sec ^3(c+d x)}{d \left (a^2+i a^2 \tan (c+d x)\right )}+\frac {3 \tan (c+d x) \sec (c+d x)}{2 a^2 d} \]

Antiderivative was successfully verified.

[In]

Int[Sec[c + d*x]^5/(a + I*a*Tan[c + d*x])^2,x]

[Out]

(3*ArcTanh[Sin[c + d*x]])/(2*a^2*d) + (3*Sec[c + d*x]*Tan[c + d*x])/(2*a^2*d) - ((2*I)*Sec[c + d*x]^3)/(d*(a^2
 + I*a^2*Tan[c + d*x]))

Rule 3500

Int[((d_.)*sec[(e_.) + (f_.)*(x_)])^(m_)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)])^(n_), x_Symbol] :> Simp[(2*d^2
*(d*Sec[e + f*x])^(m - 2)*(a + b*Tan[e + f*x])^(n + 1))/(b*f*(m + 2*n)), x] - Dist[(d^2*(m - 2))/(b^2*(m + 2*n
)), Int[(d*Sec[e + f*x])^(m - 2)*(a + b*Tan[e + f*x])^(n + 2), x], x] /; FreeQ[{a, b, d, e, f, m}, x] && EqQ[a
^2 + b^2, 0] && LtQ[n, -1] && ((ILtQ[n/2, 0] && IGtQ[m - 1/2, 0]) || EqQ[n, -2] || IGtQ[m + n, 0] || (Integers
Q[n, m + 1/2] && GtQ[2*m + n + 1, 0])) && IntegerQ[2*m]

Rule 3768

Int[(csc[(c_.) + (d_.)*(x_)]*(b_.))^(n_), x_Symbol] :> -Simp[(b*Cos[c + d*x]*(b*Csc[c + d*x])^(n - 1))/(d*(n -
 1)), x] + Dist[(b^2*(n - 2))/(n - 1), Int[(b*Csc[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1
] && IntegerQ[2*n]

Rule 3770

Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> -Simp[ArcTanh[Cos[c + d*x]]/d, x] /; FreeQ[{c, d}, x]

Rubi steps

\begin {align*} \int \frac {\sec ^5(c+d x)}{(a+i a \tan (c+d x))^2} \, dx &=-\frac {2 i \sec ^3(c+d x)}{d \left (a^2+i a^2 \tan (c+d x)\right )}+\frac {3 \int \sec ^3(c+d x) \, dx}{a^2}\\ &=\frac {3 \sec (c+d x) \tan (c+d x)}{2 a^2 d}-\frac {2 i \sec ^3(c+d x)}{d \left (a^2+i a^2 \tan (c+d x)\right )}+\frac {3 \int \sec (c+d x) \, dx}{2 a^2}\\ &=\frac {3 \tanh ^{-1}(\sin (c+d x))}{2 a^2 d}+\frac {3 \sec (c+d x) \tan (c+d x)}{2 a^2 d}-\frac {2 i \sec ^3(c+d x)}{d \left (a^2+i a^2 \tan (c+d x)\right )}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.47, size = 146, normalized size = 1.97 \[ -\frac {\sec ^2(c+d x) \left (2 \sin (c+d x)+8 i \cos (c+d x)+3 \log \left (\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right )+3 \cos (2 (c+d x)) \left (\log \left (\cos \left (\frac {1}{2} (c+d x)\right )-\sin \left (\frac {1}{2} (c+d x)\right )\right )-\log \left (\sin \left (\frac {1}{2} (c+d x)\right )+\cos \left (\frac {1}{2} (c+d x)\right )\right )\right )-3 \log \left (\sin \left (\frac {1}{2} (c+d x)\right )+\cos \left (\frac {1}{2} (c+d x)\right )\right )\right )}{4 a^2 d} \]

Antiderivative was successfully verified.

[In]

Integrate[Sec[c + d*x]^5/(a + I*a*Tan[c + d*x])^2,x]

[Out]

-1/4*(Sec[c + d*x]^2*((8*I)*Cos[c + d*x] + 3*Log[Cos[(c + d*x)/2] - Sin[(c + d*x)/2]] + 3*Cos[2*(c + d*x)]*(Lo
g[Cos[(c + d*x)/2] - Sin[(c + d*x)/2]] - Log[Cos[(c + d*x)/2] + Sin[(c + d*x)/2]]) - 3*Log[Cos[(c + d*x)/2] +
Sin[(c + d*x)/2]] + 2*Sin[c + d*x]))/(a^2*d)

________________________________________________________________________________________

fricas [B]  time = 0.57, size = 134, normalized size = 1.81 \[ \frac {3 \, {\left (e^{\left (4 i \, d x + 4 i \, c\right )} + 2 \, e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right )} \log \left (e^{\left (i \, d x + i \, c\right )} + i\right ) - 3 \, {\left (e^{\left (4 i \, d x + 4 i \, c\right )} + 2 \, e^{\left (2 i \, d x + 2 i \, c\right )} + 1\right )} \log \left (e^{\left (i \, d x + i \, c\right )} - i\right ) - 6 i \, e^{\left (3 i \, d x + 3 i \, c\right )} - 10 i \, e^{\left (i \, d x + i \, c\right )}}{2 \, {\left (a^{2} d e^{\left (4 i \, d x + 4 i \, c\right )} + 2 \, a^{2} d e^{\left (2 i \, d x + 2 i \, c\right )} + a^{2} d\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^5/(a+I*a*tan(d*x+c))^2,x, algorithm="fricas")

[Out]

1/2*(3*(e^(4*I*d*x + 4*I*c) + 2*e^(2*I*d*x + 2*I*c) + 1)*log(e^(I*d*x + I*c) + I) - 3*(e^(4*I*d*x + 4*I*c) + 2
*e^(2*I*d*x + 2*I*c) + 1)*log(e^(I*d*x + I*c) - I) - 6*I*e^(3*I*d*x + 3*I*c) - 10*I*e^(I*d*x + I*c))/(a^2*d*e^
(4*I*d*x + 4*I*c) + 2*a^2*d*e^(2*I*d*x + 2*I*c) + a^2*d)

________________________________________________________________________________________

giac [A]  time = 0.90, size = 95, normalized size = 1.28 \[ \frac {\frac {3 \, \log \left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 1\right )}{a^{2}} - \frac {3 \, \log \left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1\right )}{a^{2}} - \frac {2 \, {\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - 4 i \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + 4 i\right )}}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1\right )}^{2} a^{2}}}{2 \, d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^5/(a+I*a*tan(d*x+c))^2,x, algorithm="giac")

[Out]

1/2*(3*log(tan(1/2*d*x + 1/2*c) + 1)/a^2 - 3*log(tan(1/2*d*x + 1/2*c) - 1)/a^2 - 2*(tan(1/2*d*x + 1/2*c)^3 - 4
*I*tan(1/2*d*x + 1/2*c)^2 + tan(1/2*d*x + 1/2*c) + 4*I)/((tan(1/2*d*x + 1/2*c)^2 - 1)^2*a^2))/d

________________________________________________________________________________________

maple [B]  time = 0.37, size = 170, normalized size = 2.30 \[ -\frac {1}{2 a^{2} d \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}+\frac {2 i}{a^{2} d \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}-\frac {1}{2 d \,a^{2} \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )^{2}}-\frac {3 \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )}{2 a^{2} d}-\frac {1}{2 a^{2} d \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}-\frac {2 i}{a^{2} d \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}+\frac {1}{2 d \,a^{2} \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )^{2}}+\frac {3 \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )+1\right )}{2 a^{2} d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sec(d*x+c)^5/(a+I*a*tan(d*x+c))^2,x)

[Out]

-1/2/a^2/d/(tan(1/2*d*x+1/2*c)-1)+2*I/a^2/d/(tan(1/2*d*x+1/2*c)-1)-1/2/d/a^2/(tan(1/2*d*x+1/2*c)-1)^2-3/2/a^2/
d*ln(tan(1/2*d*x+1/2*c)-1)-1/2/a^2/d/(tan(1/2*d*x+1/2*c)+1)-2*I/a^2/d/(tan(1/2*d*x+1/2*c)+1)+1/2/d/a^2/(tan(1/
2*d*x+1/2*c)+1)^2+3/2/a^2/d*ln(tan(1/2*d*x+1/2*c)+1)

________________________________________________________________________________________

maxima [B]  time = 0.61, size = 167, normalized size = 2.26 \[ -\frac {\frac {2 \, {\left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} - \frac {4 i \, \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac {\sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}} + 4 i\right )}}{a^{2} - \frac {2 \, a^{2} \sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac {a^{2} \sin \left (d x + c\right )^{4}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{4}}} - \frac {3 \, \log \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + 1\right )}{a^{2}} + \frac {3 \, \log \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} - 1\right )}{a^{2}}}{2 \, d} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^5/(a+I*a*tan(d*x+c))^2,x, algorithm="maxima")

[Out]

-1/2*(2*(sin(d*x + c)/(cos(d*x + c) + 1) - 4*I*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 + sin(d*x + c)^3/(cos(d*x +
 c) + 1)^3 + 4*I)/(a^2 - 2*a^2*sin(d*x + c)^2/(cos(d*x + c) + 1)^2 + a^2*sin(d*x + c)^4/(cos(d*x + c) + 1)^4)
- 3*log(sin(d*x + c)/(cos(d*x + c) + 1) + 1)/a^2 + 3*log(sin(d*x + c)/(cos(d*x + c) + 1) - 1)/a^2)/d

________________________________________________________________________________________

mupad [B]  time = 3.93, size = 104, normalized size = 1.41 \[ \frac {3\,\mathrm {atanh}\left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{a^2\,d}-\frac {\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{a^2}+\frac {\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{a^2}-\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\,4{}\mathrm {i}}{a^2}+\frac {4{}\mathrm {i}}{a^2}}{d\,\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4-2\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2+1\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(1/(cos(c + d*x)^5*(a + a*tan(c + d*x)*1i)^2),x)

[Out]

(3*atanh(tan(c/2 + (d*x)/2)))/(a^2*d) - (tan(c/2 + (d*x)/2)^3/a^2 - (tan(c/2 + (d*x)/2)^2*4i)/a^2 + 4i/a^2 + t
an(c/2 + (d*x)/2)/a^2)/(d*(tan(c/2 + (d*x)/2)^4 - 2*tan(c/2 + (d*x)/2)^2 + 1))

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ - \frac {\int \frac {\sec ^{5}{\left (c + d x \right )}}{\tan ^{2}{\left (c + d x \right )} - 2 i \tan {\left (c + d x \right )} - 1}\, dx}{a^{2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)**5/(a+I*a*tan(d*x+c))**2,x)

[Out]

-Integral(sec(c + d*x)**5/(tan(c + d*x)**2 - 2*I*tan(c + d*x) - 1), x)/a**2

________________________________________________________________________________________